From 4f1a51f6586d684f5cc5dfa1fca00314882186ee Mon Sep 17 00:00:00 2001 From: Luca Bruno Date: Sun, 14 Feb 2016 16:09:38 +0100 Subject: [PATCH] patches: add clean-win-crates.patch --- debian/patches/clean-win-crates.patch | 45 +++++++++++++++++++++++++++ debian/patches/series | 1 + 2 files changed, 46 insertions(+) create mode 100644 debian/patches/clean-win-crates.patch diff --git a/debian/patches/clean-win-crates.patch b/debian/patches/clean-win-crates.patch new file mode 100644 index 000000000..b03d73e31 --- /dev/null +++ b/debian/patches/clean-win-crates.patch @@ -0,0 +1,45 @@ +Fromm: Luca Bruno +Description: Remove extra dependencies for Windows + Some crates incorrectly wants to build Windows dependencies also + on Linux. As we don't want to build/embed those, we clean them + here. +Forwarded: not-needed +--- a/deps/time-0.1.34/Cargo.toml ++++ b/deps/time-0.1.34/Cargo.toml +@@ -13,8 +13,8 @@ + + [dependencies] + libc = "0.2.1" +-winapi = "0.2.0" +-kernel32-sys = "0.2.0" ++#winapi = "0.2.0" ++#kernel32-sys = "0.2.0" + rustc-serialize = { version = "0.3", optional = true } + + [dev-dependencies] +--- a/deps/filetime-0.1.7/Cargo.toml ++++ b/deps/filetime-0.1.7/Cargo.toml +@@ -14,8 +14,8 @@ + + [dependencies] + libc = "0.2" +-kernel32-sys = "0.1" +-winapi = "0.2" ++#kernel32-sys = "0.1" ++#winapi = "0.2" + + [dev-dependencies] + tempdir = "0.3" +--- a/deps/filetime-0.1.7/src/lib.rs ++++ b/deps/filetime-0.1.7/src/lib.rs +@@ -35,8 +35,8 @@ + //! ``` + + extern crate libc; +-extern crate winapi; +-extern crate kernel32; ++#[cfg(windows)] extern crate winapi; ++#[cfg(windows)] extern crate kernel32; + + #[cfg(unix)] use std::os::unix::prelude::*; + #[cfg(windows)] use std::os::windows::prelude::*; diff --git a/debian/patches/series b/debian/patches/series index fe1579be8..d1ce6142c 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,2 +1,3 @@ clean-cargo-deps.patch libgit2-fixes.patch +clean-win-crates.patch -- 2.30.2